using System;
using Gtk;

public partial class MainWindow: Gtk.Window
{	
	public MainWindow (): base (Gtk.WindowType.Toplevel)
	{
		Build ();
		setupwindow();
		akdatabase.setup.initConnection();
		akdatabase.setup.createTables();
		akdatabase.setup.addDummyItems();
	}
		
	private void setupwindow()
	{
		// sets the title
		this.Title = akvars.strings.programname + " " + akvars.strings.programversion;
	
		// sets the dimensions of the window
		this.SetSizeRequest(akvars.parameters.mainwindow.width,akvars.parameters.mainwindow.height);
	}	
	
	protected void OnDeleteEvent (object sender, DeleteEventArgs a)
	{
		Application.Quit ();
		a.RetVal = true;
	}
}